package cn.zct.domain.activity.service.trial.thread;

import cn.zct.domain.activity.adapter.repository.IActivityRepository;
import cn.zct.domain.activity.model.valobj.SkuVO;

import java.util.concurrent.Callable;

public class QuerySkuVOFromDBThreadTask implements Callable<SkuVO> {

    private final String goodsId;

    private final IActivityRepository repository;

    public QuerySkuVOFromDBThreadTask(String goodsId, IActivityRepository repository) {
        this.goodsId = goodsId;
        this.repository = repository;
    }
    @Override
    public SkuVO call() throws Exception {

        return repository.querySkuByGoodsId(goodsId);
    }
}
